From 32f6e0a4ce7df5383b24dfde8de94e2176920fa3 Mon Sep 17 00:00:00 2001 From: Raja R Harinath Date: Mon, 29 Mar 1999 00:15:02 +0000 Subject: [PATCH] Make sure `gdkconfig.h' exists after the rule is fired. * gdk/Makefile.am (gdkconfig.h): Make sure `gdkconfig.h' exists after the rule is fired. (install-exec-local): Install gdkconfig.h only if the contents are different from the currently installed gdkconfig.h. Rationale: `make install-exec' is meant to install files that go into $exec_prefix, which includes `gdkconfig.h'. However, developers use `make install-exec' when they know that none of the headers have changed, to prevent needless recompiles of other packages. My previous change of installing `*config.h' during `make install-exec' undermines this, even though it is the right thing to do. So, in the spirit of "do the right thing first, optimize later", here's the optimization. --- ChangeLog | 7 +++++++ ChangeLog.pre-2-0 | 7 +++++++ ChangeLog.pre-2-10 | 7 +++++++ ChangeLog.pre-2-2 | 7 +++++++ ChangeLog.pre-2-4 | 7 +++++++ ChangeLog.pre-2-6 | 7 +++++++ ChangeLog.pre-2-8 | 7 +++++++ gdk/Makefile.am | 14 ++++++++++---- 8 files changed, 59 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 1e82f8e503..75d8e00020 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +1999-03-28 Raja R Harinath + + * gdk/Makefile.am (gdkconfig.h): Make sure `gdkconfig.h' exists + after the rule is fired. + (install-exec-local): Install gdkconfig.h only if the contents are + different from the currently installed gdkconfig.h. + 1999-03-26 Raja R Harinath * gdk/Makefile.am (configexecincludedir): Rename from diff --git a/ChangeLog.pre-2-0 b/ChangeLog.pre-2-0 index 1e82f8e503..75d8e00020 100644 --- a/ChangeLog.pre-2-0 +++ b/ChangeLog.pre-2-0 @@ -1,3 +1,10 @@ +1999-03-28 Raja R Harinath + + * gdk/Makefile.am (gdkconfig.h): Make sure `gdkconfig.h' exists + after the rule is fired. + (install-exec-local): Install gdkconfig.h only if the contents are + different from the currently installed gdkconfig.h. + 1999-03-26 Raja R Harinath * gdk/Makefile.am (configexecincludedir): Rename from diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10 index 1e82f8e503..75d8e00020 100644 --- a/ChangeLog.pre-2-10 +++ b/ChangeLog.pre-2-10 @@ -1,3 +1,10 @@ +1999-03-28 Raja R Harinath + + * gdk/Makefile.am (gdkconfig.h): Make sure `gdkconfig.h' exists + after the rule is fired. + (install-exec-local): Install gdkconfig.h only if the contents are + different from the currently installed gdkconfig.h. + 1999-03-26 Raja R Harinath * gdk/Makefile.am (configexecincludedir): Rename from diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2 index 1e82f8e503..75d8e00020 100644 --- a/ChangeLog.pre-2-2 +++ b/ChangeLog.pre-2-2 @@ -1,3 +1,10 @@ +1999-03-28 Raja R Harinath + + * gdk/Makefile.am (gdkconfig.h): Make sure `gdkconfig.h' exists + after the rule is fired. + (install-exec-local): Install gdkconfig.h only if the contents are + different from the currently installed gdkconfig.h. + 1999-03-26 Raja R Harinath * gdk/Makefile.am (configexecincludedir): Rename from diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4 index 1e82f8e503..75d8e00020 100644 --- a/ChangeLog.pre-2-4 +++ b/ChangeLog.pre-2-4 @@ -1,3 +1,10 @@ +1999-03-28 Raja R Harinath + + * gdk/Makefile.am (gdkconfig.h): Make sure `gdkconfig.h' exists + after the rule is fired. + (install-exec-local): Install gdkconfig.h only if the contents are + different from the currently installed gdkconfig.h. + 1999-03-26 Raja R Harinath * gdk/Makefile.am (configexecincludedir): Rename from diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6 index 1e82f8e503..75d8e00020 100644 --- a/ChangeLog.pre-2-6 +++ b/ChangeLog.pre-2-6 @@ -1,3 +1,10 @@ +1999-03-28 Raja R Harinath + + * gdk/Makefile.am (gdkconfig.h): Make sure `gdkconfig.h' exists + after the rule is fired. + (install-exec-local): Install gdkconfig.h only if the contents are + different from the currently installed gdkconfig.h. + 1999-03-26 Raja R Harinath * gdk/Makefile.am (configexecincludedir): Rename from diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8 index 1e82f8e503..75d8e00020 100644 --- a/ChangeLog.pre-2-8 +++ b/ChangeLog.pre-2-8 @@ -1,3 +1,10 @@ +1999-03-28 Raja R Harinath + + * gdk/Makefile.am (gdkconfig.h): Make sure `gdkconfig.h' exists + after the rule is fired. + (install-exec-local): Install gdkconfig.h only if the contents are + different from the currently installed gdkconfig.h. + 1999-03-26 Raja R Harinath * gdk/Makefile.am (configexecincludedir): Rename from diff --git a/gdk/Makefile.am b/gdk/Makefile.am index d5e5ae5a72..6bb478351d 100644 --- a/gdk/Makefile.am +++ b/gdk/Makefile.am @@ -2,7 +2,7 @@ gdkincludedir = $(includedir)/gdk -configexecincludedir = $(pkglibdir)/include + lib_LTLIBRARIES = libgdk.la @@ -74,12 +74,18 @@ libgdk_la_LDFLAGS = \ @x_libs@ \ -lm -configexecinclude_DATA = \ - gdkconfig.h +configexecincludedir = $(pkglibdir)/include +#configexecinclude_DATA = gdkconfig.h +install-exec-local: gdkconfig.h + $(mkinstalldirs) $(DESTDIR)$(configexecincludedir) + file=$(DESTDIR)$(configexecincludedir)/gdkconfig.h; \ + if test -r $$file && cmp -s gdkconfig.h $$file; then :; \ + else $(INSTALL_DATA) gdkconfig.h $$file; fi BUILT_SOURCES = stamp-gc-h #note: not gdkconfig.h gdkconfig.h: stamp-gc-h - @: + @if test -f gdkconfig.h; then :; \ + else rm -f stamp-gc-h; $(MAKE) stamp-gc-h; fi stamp-gc-h: ../config.status cd .. && CONFIG_FILES= CONFIG_HEADERS= CONFIG_OTHER=gdk/gdkconfig.h ./config.status echo timestamp > stamp-gc-h -- 2.30.2